from django.conf.urls.defaults import patterns, include, url
from b52.home.views import *
from django.contrib import admin
# Uncomment the next two lines to enable the admin:
# from django.contrib import admin
admin.autodiscover()

urlpatterns = patterns('',
    # Examples:
    # url(r'^$', 'b52.views.home', name='home'),
    # url(r'^b52/', include('b52.foo.urls')),

    # Uncomment the admin/doc line below to enable admin documentation:
    # url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
    (r'^media/(?P<path>.*)$', 'django.views.static.serve',
    {'document_root': '/media'}),
    
    #url(r'^sentry/', include('sentry.urls')),

    url(r'^admin_tools/', include('admin_tools.urls')),
    # Uncomment the next line to enable the admin:
    url(r'^admin/', include(admin.site.urls)),

    url(r'^category/(?P<num>\w+)/$', category),
    url(r'^goods/page(?P<page>\d+)/', goods), 
    url(r'^goods/uid(?P<UID>\w+)/', goods),
    #url(r'^(\w+)/$', company),
    url(r'^blog/page(?P<num>\d+)/$', page),
    url(r'^login*', 'django.contrib.auth.views.login', {'template_name': 'login.html'}),
    
    url(r'^generate/(?P<name>\w+)/', generate),
    
    url(r'^$', index_b52),
    
    url(r'^join/$', UserRegistration),
    
    #(r'^sentry/', include('sentry.urls')),
    #url(r'^reg/$', registration),
)
